package com.ssy.lingxi.member.merchant.model.vo.validate.request;

import com.ssy.lingxi.member.merchant.api.handler.annotation.EnableDisableStatusAnno;
import com.ssy.lingxi.member.merchant.handler.annotation.DateStringFormatAnnotation;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * 会员入库资料 - 资质证明文件接口参数Vo
 * @author 万宁
 * @version 2.0.0
 * @date 2021-05-19
 */
public class MemberQualityVO implements Serializable {
    private static final long serialVersionUID = -7190733829668515580L;

    /**
     * 文件Url
     */
    @NotBlank(message = "资质文件Url不能为空")
    @Size(max = 400, message = "资质文件Url最长400个字符")
    private String url;

    /**
     * 文件名称
     */
    @NotBlank(message = "资质文件名称不能为空")
    @Size(max = 255, message = "资质文件名称最长255个字符")
    private String name;

    /**
     * 有效日期，格式为yyyy-MM-dd，当permanent=0时必填
     */
    @DateStringFormatAnnotation(message = "资质文件有效日期格式错误")
    private String expireDay;

    /**
     * 是否长期有效，0-否，1-是
     */
    @EnableDisableStatusAnno(message = "'是否长期有效'取值范围为0-1")
    private Integer permanent;

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getExpireDay() {
        return expireDay;
    }

    public void setExpireDay(String expireDay) {
        this.expireDay = expireDay;
    }

    public Integer getPermanent() {
        return permanent;
    }

    public void setPermanent(Integer permanent) {
        this.permanent = permanent;
    }
}
